package com.zhima.feignclient;

import com.zhima.enums.UserQuestionState;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestMapping;

@FeignClient("question-service")
@RequestMapping("/oj-question/user-question/feign")
public interface UserQuestionFeignClient {
    /**
     * 增加用户做题的记录
     *
     * @param questionId
     * @param userQuestionState
     * @return
     */
    @PutMapping("/{userId}/{questionId}/{userQuestionState}")
    boolean addUserQuestion(@PathVariable("userId") Long userId, @PathVariable("questionId") Long questionId, @PathVariable UserQuestionState userQuestionState);
}
